#!/usr/bin/env python
# _*_ encoding:utf-8 _*_
import subprocess


def run_command(command):
    p = subprocess.Popen(command, stdout=subprocess.PIPE,stderr=subprocess.STDOUT)
    return iter(p.stdout.readline(), b'')

if __name__ == '__main__':
    for output_line in run_command(
            'java -jar D:\workspace\idea\hbsf\sfrobot-javafx\target\sfrobot-javafx-0.0.1-SNAPSHOT.jar'):
        print(output_line)
